package com.pureut.equipment.mapper;

import com.baomidou.mybatisplus.core.mapper.BaseMapper;
import com.baomidou.mybatisplus.extension.plugins.pagination.Page;
import com.pureut.equipment.domain.PatrolItem;
import com.pureut.equipment.domain.dto.PatrolItemDto;
import com.pureut.equipment.domain.vo.PatrolItemVo;
import org.apache.ibatis.annotations.Mapper;
import org.apache.ibatis.annotations.Param;

import java.util.List;

/***
 *
 * Author:巡检项目mapper
 * Date:2023/04/26 9:53
 * @DESC
 */
@Mapper
public interface PatrolItemMapper extends BaseMapper<PatrolItem> {

    /**
     * 巡检项目列表
     */
    Page<PatrolItemDto> getList(@Param("patrolItemVo") PatrolItemVo patrolItemVo, @Param("page") Page<PatrolItemDto> page);

    /**
     * 根据id获取数据
     */
    PatrolItemDto getDataById(Long id);

    /**
     * 循环获取项目列表
     */
    List<PatrolItem> getAllList(@Param("patrolItemIds") List<String> patrolItemIds);

    /**
     * 根据多个id查询巡检项目数据
     * @param patrolItemIds
     */
    List<PatrolItemDto> selectPatrolItemByIds(@Param("patrolItemIds") List<String> patrolItemIds);
}
